<?php
/**
 * Job Form
 *
 */
use Fox\Generator;
use Fox\Html\DropList;
use Fox\Html\Input;
use Fox\Html\TextArea;
$bkjob = new Fox\Html\Block('jobInfo');

$bkjob->add(new Input('jobtitle',true))->size(20)->labelSize('100')
		->activateTabIndex(1);
$bkjob->add(new Input(array('company','companyName'),false),2)
			->labelSize('60')
			->activateTabIndex(2)
			->autocomplete(Generator::url('company','autocomplete'))
			->size(20);
$types = Fox\Dao::finder(Hive\Job\Contract\Type::className())
		->where('active = ? AND loekz = ?',array(1,0))
		->find();
$bkjob->add(new DropList('contract_type',true,false,false))
			->labelSize('100')
			->activateTabIndex(3)
			->options($types,'type',Fox\Generator::call('label'))
			->size(120);
$bkjob->add(new Input('start_date',true))
			->labelSize('100')
			->activateTabIndex(4);
$bkjob->add(new Input('end_date',false),2,'start_date')
		->activateTabIndex(5)
		->labelSize('60');
$bkjob->add(new Input('salary',false))
		->labelSize('100')
		->activateTabIndex(6);
$bkjob->add(new Input('bonus',false),2,'salary')
		->labelSize('60')
		->activateTabIndex(7);
$bkjob->add(new TextArea('comment',false,null,100,10),1)
		->labelSize('100')
		->width('90%')
		->colspan(2)
		->activateTabIndex(8);
if(isset($params['data']))
{
	$bkjob->initialize($params['data']);
}
return $bkjob;